import Vue from 'vue'
import echarts from 'echarts/lib/echarts'
import vcharts from '@/components/vcharts'
import option from './option'
import defaultTheme from './theme.default'

// 柱状图
require('echarts/lib/chart/bar');
// 线图
require('echarts/lib/chart/line');
// 饼图
require('echarts/lib/chart/pie');
// 散点图
require('echarts/lib/chart/scatter');
require('echarts/lib/chart/effectScatter');
// 雷达图
require('echarts/lib/chart/radar');
// 仪表盘
require('echarts/lib/chart/gauge');
// 热力图
require('echarts/lib/chart/heatmap');
require('echarts/lib/chart/custom');
require('echarts/lib/chart/graph');

// 组件
require('echarts/lib/component/tooltip');
require('echarts/lib/component/title');
require('echarts/lib/component/legendScroll');
require('echarts/lib/component/legend');
require("echarts/lib/component/markPoint");
require("echarts/lib/component/markLine");
require("echarts/lib/component/markArea");
require("echarts/lib/component/axisPointer");
require("echarts/lib/component/toolbox");

echarts.registerTheme('vae', defaultTheme);

window.echarts = echarts;
window.echartsOption = option;

Vue.component("vae-echarts", vcharts);
